<!-- <button (click) = "getDatabases()" >获取所有数据库</button>
<button (click) = "connectServer()">链接数据库服务器</button> -->
<!-- <button nz-button (click)="printEval()"></button> -->
<div nz-row>
    <div nz-col nzSpan="6">
    <div>
        <div> <!-- 左侧树形结构 -->
            <div nz-row nzType="flex" nzJustify="space-around" nzAlign="middle">
                <div nz-col nzSpan="14" class="treeSearchInput">
                    <nz-input-group [nzSuffix]="suffixIcon">
                        <input #searchInput type="text" nz-input placeholder="Search" [(ngModel)]="searchValue"
                            (ngModelChange)="searchChange($event)"/>
                    </nz-input-group>
                    <ng-template #suffixIcon>
                        <i nz-icon nzType="search"></i>
                    </ng-template>
                </div>

                <div nz-col nzSpan="2" class="treeLinker">
                    <a nz-tooltip nzTooltipTitle="更新本地数据" (click)="refreshLocalData()"><i nz-icon nzType="sync" nzTheme="outline"></i></a>
                </div>

                <div nz-col nzSpan="2" class="treeLinker">
                    <a nz-tooltip nzTooltipTitle="连接服务器" (click)="connectServer()"><i nz-icon nzType="link" nzTheme="outline"></i></a>
                </div>

                <div nz-col nzSpan="3" class="treeMatchSwitcher">
                    <nz-switch nzSize="small" [(ngModel)]="hideUnMatched" nz-tooltip nzTooltipTitle="隐藏非匹配" (click)="clickSwitcher()"></nz-switch>
                </div>
            </div>


            <div nz-col nzSpan="24" class="treeContainer">
            <nz-tree #tree [nzData]="treeData" [nzSearchValue]="delayedSearchValue" (nzClick)="treeClick($event)"
                [nzHideUnMatched]="hideUnMatched"
                (nzExpandChange)="treeNodeExpand($event)"
                (nzSearchValueChange)="searchValueChange($event)">
            </nz-tree>
            </div>
        </div>
    </div>
    </div>

    <!-- 右侧编辑区域 -->
    <div nz-col nzSpan="18">
        <div nz-col nzSpan="24" class="editorContainer" nzGutter="24">

            <div nz-row nzType="flex" nzJustify="start">
                <div nz-col nzSpan="16" class="toolBarContainer" style="padding-left: 10px;">
                    <!-- 主菜单 -->
                    <div nz-row nzType="flex" nzGutter="24">
                        <!-- Mybatis -->
                        <div nz-col [nzSpan]="spanMenuTool">
                            <a nz-dropdown [nzDropdownMenu]="menu_mybatis">
                                Mybatis<i nz-icon nzType="down"></i>
                            </a>
                            <nz-dropdown-menu #menu_mybatis="nzDropdownMenu">
                                <ul nz-menu>
                                    <li nz-menu-item
                                    nz-popover nzPopoverTitle="设置模型包名路径："
                                    [(nzVisible)]="popOverVisible_createMybatisSaveOne"
                                    (nzVisibleChange)="change_createMybatisSaveOne($event)"
                                    nzPopoverTrigger="click"
                                    [nzPopoverContent]="contentTemplate_createMybatisSaveOne">单行新增/修改</li>

                                    <li nz-menu-item
                                    nz-popconfirm
                                    nzPopconfirmTitle="使用字段原始名称作为属性名？"
                                    nzOkText="是"
                                    nzCancelText="否"
                                    (nzOnConfirm)="createMybatisSaveBatch(true)"
                                    (nzOnCancel)="createMybatisSaveBatch(false)">批量新增/修改</li>
                                    <li nz-menu-item (click)="createMybatisSelectAll()">selectAll</li>
                                    <li nz-menu-item (click)="drawerVisible_MybatisResultMap = !drawerVisible_MybatisResultMap">前后缀ResultMap</li>
                                </ul>
                            </nz-dropdown-menu>
                        </div>

                        <!-- Spring -->
                        <div nz-col [nzSpan]="spanMenuTool">
                            <a nz-dropdown [nzDropdownMenu]="menu_spring">
                                Spring<i nz-icon nzType="down"></i>
                            </a>
                            <nz-dropdown-menu #menu_spring="nzDropdownMenu">
                                <ul nz-menu>
                                    <li nz-menu-item
                                    (click)="createSpringDao()"
                                    nz-popover nzPopoverTitle="设置模型类名称："
                                    [(nzVisible)]="popOverVisible_createSpringDao"
                                    nzPopoverTrigger="click"
                                    [nzPopoverContent]="contentTemplate_createSpringDao">DAO自定义三剑客</li>

                                    <li nz-menu-item
                                    (click)=" popOverVisible_createSpringService = !popOverVisible_createSpringService"
                                    nz-popover nzPopoverTitle="模型类名称："
                                    [(nzVisible)]="popOverVisible_createSpringService"
                                    (nzVisibleChange)="change_createMybatisSaveOne($event)"
                                    nzPopoverTrigger="click"
                                    [nzPopoverContent]="contentTemplate_createSpringService">服务接口</li>

                                    <li nz-menu-item
                                    (click)=" popOverVisible_createSpringServiceImpl = !popOverVisible_createSpringServiceImpl"
                                    nz-popover nzPopoverTitle="模型类名："
                                    [(nzVisible)]="popOverVisible_createSpringServiceImpl"
                                    (nzVisibleChange)="change_createMybatisSaveOne($event)"
                                    nzPopoverTrigger="click"
                                    [nzPopoverContent]="contentTemplate_createSpringServiceImpl">服务实现类</li>
                                    <li nz-menu-item
                                    (click)="createSpringController()"
                                    nz-popover nzPopoverTitle="设置模型类名称："
                                    [(nzVisible)]="popOverVisible_createSpringController"
                                    nzPopoverTrigger="click"
                                    [nzPopoverContent]="contentTemplate_createSpringController">controller</li>

                                    <li nz-menu-item (click)="drawerVisible_preSuffixJavaModel = !drawerVisible_preSuffixJavaModel">
                                        前后缀JavaModel
                                    </li>

                                </ul>
                            </nz-dropdown-menu>
                        </div>

                        <!-- Angular -->
                        <div nz-col [nzSpan]="spanMenuTool">
                            <a nz-dropdown [nzDropdownMenu]="menu_angular">
                                Angular<i nz-icon nzType="down"></i>
                            </a>
                            <nz-dropdown-menu #menu_angular="nzDropdownMenu">
                                <ul nz-menu>
                                    <li nz-menu-item nzDisabled>单表类型</li>
                                    <li nz-menu-item (click)="createAngularService()">服务类</li>
                                    <li nz-menu-item (click)="drawerVisible_angularModel = !drawerVisible_angularModel">model</li>
                                    <li nz-menu-item (click)="createSingleTemplate()">模板代码</li>
                                    <li nz-menu-item (click)="visible_SingleControllerForm = !visible_SingleControllerForm">控制器代码</li>

                                    <li nz-menu-divider></li>
                                    <li nz-menu-item nzDisabled>单据序时表</li>
                                    <li nz-menu-item (click)="drawerVisible_chroRptService = true">服务类</li>
                                    <li nz-menu-item (click)="angularModel = mysqlService.createChroRptCSS()">CSS</li>
                                    <li nz-menu-item (click)="angularModel = mysqlService.createChroRptHtml()">模板代码</li>
                                    <li nz-menu-item (click)="drawerVisible_chroRptController = true">控制器代码</li>

                                    <li nz-menu-divider></li>
                                    <li nz-menu-item nzDisabled>模块相关</li>
                                    <li nz-menu-item (click)="createModuleImports()">模块引用代码</li>
                                    
                                </ul>
                            </nz-dropdown-menu>
                        </div>

                        <!-- DataBase -->
                        <div nz-col [nzSpan]="spanMenuTool">
                            <a nz-dropdown [nzDropdownMenu]="menu_database">
                                DataBase<i nz-icon nzType="down"></i>
                            </a>
                            <nz-dropdown-menu #menu_database="nzDropdownMenu">
                                <ul nz-menu>
                                    <li nz-menu-item (click)="createFieldString()">生成字段字符串</li>
                                    <li nz-menu-item (click)="visible_CreateSQL_pks2Records = true">主键字串对应记录集</li>

                                    <li nz-menu-divider></li>
                                    <li nz-menu-item nzDisabled>快速开发框架</li>
                                    <li nz-menu-item (click)="drawerVisible_insertTableStyle = !drawerVisible_insertTableStyle">生成table_style插入数据</li>
                                    <li nz-menu-item (click)="modalVisible_charSet = !modalVisible_charSet">修改varchar字段字符集</li>
                                    <li nz-menu-item (click)="modalVisible_emptyString = !modalVisible_emptyString">设置varchar默认空字符串</li>
                                </ul>
                            </nz-dropdown-menu>
                        </div>

                        <!-- General -->
                        <div nz-col [nzSpan]="spanMenuTool">
                            <a nz-dropdown [nzDropdownMenu]="menu_general">
                                General<i nz-icon nzType="down"></i>
                            </a>
                            <nz-dropdown-menu #menu_general="nzDropdownMenu">
                                <ul nz-menu>
                                    <li nz-menu-item (click)="menuGeneralModel()">公共模型</li>
                                    <li nz-menu-item (click)="menuGeneralArrayUtils()">数组工具类</li>
                                    <li nz-menu-item (click)="menuGeneralStringUtils()">字符串工具类</li>
                                </ul>
                            </nz-dropdown-menu>
                        </div>
                    </div>

                    <!-- 生成 Spring Controller -->
                    <ng-template #contentTemplate_createSpringController>
                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle"
                            style="width:400px;">
                            <div nz-col nzSpan="18">
                                <input type="text" nz-input [(ngModel)]="modelName_createSpringController" (keydown.enter)="createSpringControllerGo()"/>
                            </div>

                            <div nz-col nzSpan="4">
                                <button nz-button nzType="primary" (click)="createSpringControllerGo()">确定</button>
                            </div>
                        </div>
                    </ng-template>

                    <!-- 生成 spring 实现类 -->
                    <ng-template #contentTemplate_createSpringServiceImpl>
                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
                            <div nz-col nzSpan="18">
                                <input type="text" nz-input [(ngModel)]="modelName_CreateSpringServiceImpl" (keydown.enter)="createSrpingServiceImpl()"/>
                            </div>

                            <div nz-col nzSpan="4">
                                <button nz-button nzType="primary" (click)="createSrpingServiceImpl()">确定</button>
                            </div>
                        </div>
                    </ng-template>

                    <!-- 生成 spring 服务接口 -->
                    <ng-template #contentTemplate_createSpringService>
                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
                            <div nz-col nzSpan="18">
                                <input type="text" nz-input [(ngModel)]="modelName_CreateSpringService" (keydown.enter)="createSrpingService()"/>
                            </div>

                            <div nz-col nzSpan="4">
                                <button nz-button nzType="primary" (click)="createSrpingService()">确定</button>
                            </div>
                        </div>
                    </ng-template>

                    <!-- SpringDAO 自定义三剑客 -->
                    <ng-template #contentTemplate_createSpringDao>
                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle"
                            style="width:400px;">
                            <div nz-col nzSpan="18">
                                <input type="text" nz-input [(ngModel)]="modelName_createSpringDao" (keydown.enter)="createSpringDaoGo()"/>
                            </div>

                            <div nz-col nzSpan="4">
                                <button nz-button nzType="primary" (click)="createSpringDaoGo()">确定</button>
                            </div>
                        </div>
                    </ng-template>

                    <!-- 模板块 - 生成单行保存/修改 -->
                    <ng-template #contentTemplate_createMybatisSaveOne>
                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle"
                            style="width:400px;">
                            <div nz-col nzSpan="18">
                                <input type="text" nz-input [(ngModel)]="packagePath_createMybatisSaveOne" (keydown.enter)="save_packagePath_createMybatisSaveOne()"/>
                            </div>
                            <div nz-col nzSpan="4">
                                <button nz-button nzType="primary" (click)="save_packagePath_createMybatisSaveOne()">确定</button>
                            </div>
                        </div>

                        <div nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
                            <div nz-col nzSpan="12">
                                去下划线首字母大写：<nz-switch [(ngModel)]="upperAttribute" nzCheckedChildren="开" nzUnCheckedChildren="关"></nz-switch>
                            </div>
                        </div>
                    </ng-template>

                </div>

                <div nz-col nzSpan="6">
<!--                    服务器：{{dbConfig?.server}} - {{dbConfig?.port}} - {{dbConfig?.dbUserName}}-->
                  服务器：{{dbConfig?.server}} - {{dbConfig?.dbUserName}}
                </div>

                <!-- 显示连接到的远程服务器的参数 -->
                <!-- <div nz-row nzType="flex" nzJustify="space-around" nzAlign="middle" style="padding: 10px;">
                    <div nz-col nzSpan="24">
                        服务器：{{dbConfig?.server}} - {{dbConfig?.port}} - {{dbConfig?.dbUserName}}
                    </div>
                </div> -->

            </div>

            <!-- 代码显示区域 -->
            <div nz-row nzType="flex">
                <div nz-col nzSpan="24" class="codeZone" style="padding: 10px;">
                    <textarea rows=18 nz-input [(ngModel)]="angularModel"></textarea>
                </div>
            </div>

        </div>
    </div>
</div>


<!-- 设置数据库链接的抽屉 -->
<nz-drawer [nzWidth]="313"
    [nzClosable]="true"
    [nzVisible]="drawerVisible"
    nzPlacement="right"
    nzTitle="数据库链接设置"
    (nzOnClose)="close()"
>

<form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm()">
    <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="server">服务器</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
        <input nz-input formControlName="server" id="server" />
        </nz-form-control>
    </nz-form-item>

    <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="port">端口号</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="port" id="port" />
        </nz-form-control>
    </nz-form-item>

    <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="userName">用户名</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="userName" id="userName" />
        </nz-form-control>
    </nz-form-item>

    <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzFor="password" nzRequired>密码</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
        <input nz-input type="password" id="password" formControlName="password"/>
        </nz-form-control>
    </nz-form-item>


    <nz-form-item nz-row>
        <nz-form-control [nzSpan]="6" [nzOffset]="6">
            <button nz-button nzType="primary">连接</button>
        </nz-form-control>

        <!-- <nz-form-control [nzSpan]="6" [nzOffset]="3">
            <button nz-button nzType="default" (click)="closeDrawer($event)">关闭</button>
        </nz-form-control> -->
    </nz-form-item>
</form>

</nz-drawer>

<!-- 生成单表控制器代码需要的参数：modelName,detailService -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="visible_SingleControllerForm"
    nzPlacement="right"
    nzTitle="单表控制器需要的参数"
    (nzOnClose)="close()"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="singleControllerForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">表名称</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="tableName" name="tableName" id="tableName" placeholder="数据库表名:contact_type"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">模型类名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="modelName" name="modelName" id="modelName" placeholder="Java类名:ContactType"/>
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">服务名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="detailService" name="detailService" id="detailService" placeholder="Angular服务:ContactTypeService"/>
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">Angular模块包名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="packageName" name="packageName" id="packageName" placeholder="Angular业务包名:contact-type"/>
            </nz-form-control>
        </nz-form-item>
    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="cancelDrawerEdit()" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_SingleControllerParam()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>


<!-- 生成SQL字符串 - 根据主键字符串查询表数据 -->
<nz-drawer [nzWidth]="313"
    [nzClosable]="true"
    [nzVisible]="visible_CreateSQL_pks2Records"
    nzPlacement="right"
    nzTitle="设置参数"
    (nzOnClose)="close()"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="pks2RecordsForm">

        <nz-form-item>
            <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="server">表名称</nz-form-label>
            <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="tableName" name="tableName" id="tableName" placeholder="数据库中表名"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="server">主键字段</nz-form-label>
            <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="pkFieldName" name="pkFieldName" id="pkFieldName" placeholder="主键字段名称"/>
            </nz-form-control>
        </nz-form-item>
    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="visible_CreateSQL_pks2Records = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="createSQL_pk2Records()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>


<!-- 生成带有前后缀的 Java Model -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_preSuffixJavaModel"
    nzPlacement="right"
    nzTitle="原始字段添加前后缀"
    (nzOnClose)="drawerVisible_preSuffixJavaModel = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="preSuffixJavaModelForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">前缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="prefix" name="prefix" placeholder="前缀：m_"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">后缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="suffix" name="suffix" placeholder="后缀：_main"/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_preSuffixJavaModel = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_preSuffixJavaModelForm()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>


<!-- 生成带有前后缀的 Angular Model -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_angularModel"
    nzPlacement="right"
    nzTitle="原始字段添加前后缀"
    (nzOnClose)="drawerVisible_angularModel = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="preSuffixAngularModelForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">前缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="prefix" name="prefix" placeholder="前缀：m_"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">后缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="suffix" name="suffix" placeholder="后缀：_main"/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_angularModel = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_preSuffixAngularModelForm()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>

<!-- 生成带有前后缀的 Mybatis Result Map -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_MybatisResultMap"
    nzPlacement="right"
    nzTitle="原始字段添加前后缀"
    (nzOnClose)="drawerVisible_MybatisResultMap = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="preSuffixMybatisResultMapForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">前缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="prefix" name="prefix" placeholder="Java控制器别名"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">后缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="suffix" name="suffix" placeholder=""/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_MybatisResultMap = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_preSuffixMybatisResultMapForm()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>




<!-- 生成单据序时表服务类 -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_chroRptService"
    nzPlacement="right"
    nzTitle="生成单据序时表服务类"
    (nzOnClose)="drawerVisible_chroRptService = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="chroRptServiceForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">Java控制器</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="jControllerName" name="jControllerName" placeholder="java控制器RequestMap名称"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">主表表名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="mainTableName" name="mainTableName" />
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">明细表名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="detailTableName" name="detailTableName" />
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">融合单据名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="billName" name="billName" placeholder="小写billDye"/>
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">主表前缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="mainPrefix" name="mainPrefix" placeholder="默认m_"/>
            </nz-form-control>
        </nz-form-item>

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">明细前缀</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="detailPrefix" name="detailPrefix" placeholder="默认d_"/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_chroRptService = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_chroRptService()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>


<!-- 生成单据序时表控制器代码 -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_chroRptController"
    nzPlacement="right"
    nzTitle="原始字段添加前后缀"
    (nzOnClose)="drawerVisible_chroRptController = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="chroRptControllerForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">服务名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="serviceName" name="serviceName" placeholder="类似：rpt-chro-bill"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">单据融合类</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="billModel" name="billModel" placeholder="bill->BillExplode"/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_chroRptController = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_chroRptControllerForm()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>




<!-- 生成SQL语句，向表 table_style 写入数据 - 指定表名的所有字段  -->
<nz-drawer [nzWidth]="500"
    [nzClosable]="true"
    [nzVisible]="drawerVisible_insertTableStyle"
    nzPlacement="right"
    nzTitle="生成插入table_style的SQL语句"
    (nzOnClose)="drawerVisible_insertTableStyle = false"
>
    <form nz-form [nzLayout]="'horizontal'" [formGroup]="insertTableStyleForm">

        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">数据库</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="dbName" name="dbName" placeholder="数据库名称"/>
            </nz-form-control>
        </nz-form-item>


        <nz-form-item>
            <nz-form-label [nzSm]="CAPTION_WIDTH01" [nzXs]="24" nzRequired nzFor="server">表名</nz-form-label>
            <nz-form-control [nzSm]="CONTROL_WIDTH01" [nzXs]="24" nzErrorTip="必填项">
            <input nz-input formControlName="tableName" name="tableName" placeholder="表名"/>
            </nz-form-control>
        </nz-form-item>

    </form>


    <div class="footer" nz-row nzType="flex" nzJustify="space-between" nzAlign="middle">
        <div nz-col nzSpan="20" nzOffset="4">
            <button type="button" (click)="drawerVisible_insertTableStyle = false" class="ant-btn" style="margin-right: 8px;"><span>取消</span></button>
            <button type="button" (click)="saveDrawer_insertTableStyleForm()" class="ant-btn ant-btn-primary"><span>保存</span></button>
        </div>
    </div>
</nz-drawer>


<!-- 生成批量SQL语句 - 修改数据库所有表的所有 varchar 字段的字符集 -->
<nz-modal [(nzVisible)]="modalVisible_charSet" nzTitle="批量修改字符集" (nzOnCancel)="modalVisible_charSet = false" (nzOnOk)="createSQL_characterSet()">
    <input nz-input [(ngModel)]="dbNameCharSet" id="dbNameCharSet" name="dbNameCharSet" placeholder="数据库名称">
</nz-modal>

<!-- 设置所有 varchar 类型字段默认空字符串 -->
<nz-modal [(nzVisible)]="modalVisible_emptyString" nzTitle="默认空字符串" (nzOnCancel)="modalVisible_emptyString = false" (nzOnOk)="createSQL_emptyString()">
    <input nz-input [(ngModel)]="dbNameEmptyString" id="dbNameEmptyString" name="dbNameEmptyString" placeholder="数据库名称">
</nz-modal>



<p-toast [style]="{marginTop: '80px'}" styleClass="primeng-custom-toast" key="custom" position="top-right"></p-toast>
